<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">

    <!-- 客户名称 -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Nickname')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="nickname" class="form-control" name="row[nickname]" type="text"
                placeholder="{:__('Nickname')}" />
        </div>
    </div>

    <!-- 手机号码 -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Mobile')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="mobile" class="form-control" name="row[mobile]" type="text" placeholder="请输入手机号码" />
        </div>
    </div>

    <!-- 性别 -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Gender')}:</label>
        <div class="col-xs-12 col-sm-8">
            {$genderList}
        </div>
    </div>

    <!-- 邮箱 -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Email')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="email" class="form-control" name="row[email]" type="text" placeholder="{:__('Email')}" />
        </div>
    </div>

    <!-- 地区 -->
    <div class="form-group">
        <label for="region" class="control-label col-xs-12 col-md-4 col-sm-2">{:__('Area')}:</label>
        <div class="col-xs-12 col-md-8 col-sm-8">
            <input id="region" class="form-control" data-toggle="city-picker" type="text" placeholder="请选择地区" />
            <input type="hidden" name="row[province]" />
            <input type="hidden" name="row[city]" />
            <input type="hidden" name="row[district]" />
        </div>
    </div>

    <!-- 客户来源 -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Sourceid')}:</label>
        <div class="col-xs-12 col-md-8 col-sm-8">
            {$sourceList}
        </div>
    </div>

    <!-- 余额 -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Money')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="money" min="0" class="form-control" step="0.01" name="row[money]" type="number" placeholder="{:__('Money')}" value="0.00" />
        </div>
    </div>

    <!-- 认证状态 -->
    {if condition="$sourceList"}
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Auth')}:</label>
        <div class="col-xs-12 col-sm-8">
            {$authList}
        </div>
    </div>
    {/if}

    <!-- 成交状态 -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Deal')}:</label>
        <div class="col-xs-12 col-sm-8">
            {$dealList}
        </div>
    </div>

    <!-- 头像 -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Avatar')}:</label>
        <div class="col-xs-12 col-sm-8">
            <div class="input-group">
                <!-- 上传路径 -->
                <input id="avatar" class="form-control" size="50" name="row[avatar]" type="text" value="">

                <div class="input-group-addon no-border no-padding">
                    <span><button type="button" id="faupload-avatar" class="btn btn-danger faupload"
                            data-input-id="avatar"
                            data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp,image/webp"
                            data-multiple="false" data-preview-id="p-avatar"><i class="fa fa-upload"></i>
                            {:__('Upload')}</button></span>
                    <span><button type="button" id="fachoose-avatar" class="btn btn-primary fachoose"
                            data-input-id="avatar" data-mimetype="image/*" data-multiple="false"><i
                                class="fa fa-list"></i> {:__('Choose')}</button></span>
                </div>
                <span class="msg-box n-right" for="c-avatar"></span>
            </div>
            <ul class="row list-inline faupload-preview" id="p-avatar"></ul>
        </div>
    </div>

    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-primary btn-embossed disabled">{:__('OK')}</button>
        </div>
    </div>
</form>